<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
  <head>
    <title>Stack README</title>
  </head>

  <body>
<center>
<h1> ReadMe</h1>
<A HREF="mailto:gelee@hawaii.edu">George Lee</A> <br>
<A HREF="mailto:elaynem@hawaii.edu">Elayne Man</A> <br>
<A HREF="mailto:johnson@hawaii.edu">Philip Johnson<br>
<A HREF="http://csdl.ics.hawaii.edu/">Collaborative Software Development Laboratory</A><br>
<A HREF="http://www.hawaii.edu/">University of Hawaii<br>
</A>
<p>
</center>

This file introduces you to the
major components of this software package. It includes information on the
contents of the package you have downloaded, instructions on how to install the
system, basic invocation and usage, user documentation, developer documentation,
and contact coordinates for further information.</p>

<h1>Introduction</h1><p>To get started with the development of Photo Hunt, please follow this Developers Guide to set up your environment properly. </p><h1>Basic Installation</h1><p>These instructions assume that you have unzipped the zip file containing this system to create a directory containing the system components. A note to Unix users: due to a bug in java.util.zip, the directory permissions are munged if you unzip in Unix, and you won&#x27;t be able to cd into interior directories.  To fix this, invoke the following from the parent directory of this system: chmod -R a+x &lt;system directory&gt;.  </p><ol><li>Install Java 1.5 </li><ul><li>Install the Java JDK (the full JDK, not just the JRE) by following the instructions at <a href="http://java.sun.com" rel="nofollow">http://java.sun.com</a>. </li><li>Set the JAVA_HOME environment variable to point to your Java installation (for example, c:\java\jdk1.5.0_08) </li><li>Add JAVA_HOME/bin to your PATH variable.  </li></ul></ol><ol><li>Install Ant 1.7 </li><ul><li>Download and unzip apache-ant-1.7.0Beta1.zip (or later) from <a href="http://ant.apache.org/" rel="nofollow">http://ant.apache.org/</a>.  </li><li>Set the ANT_HOME environment variable to point to your Ant installation (for example, c:\apache-ant-1.7.0Beta1) </li><li>Add ANT_HOME/bin to your PATH variable.  </li></ul></ol><ol><li>Install Tomcat 5.5.20 </li><ul><li>Download and unzip apache-tomcat-5.5.20.zip from <a href="http://tomcat.apache.org/" rel="nofollow">http://tomcat.apache.org/</a>.  DO NOT download the &quot;windows installer .exe&quot; version. </li><li>Set the CATALINA_HOME environment variable to point to your Tomcat installation (why &quot;Catalina&quot;?  Beats me. But that&#x27;s what it should be named.) </li><li>Add CATALINA_HOME/bin to your PATH variable.  </li></ul></ol><ol><li>Configure Tomcat for Ant-based deployment. </li><ul><li>Copy the &quot;sample.tomcat-users.xml&quot; file to &lt;tomcat&gt;/conf/tomcat-users.xml.  You will overwrite the default tomcat-users.xml. This sets up an admin role and password consistent with the value found in tomcat.build.xml.  </li></ul></ol><ol><li>Configure Eclipse for building the system </li><ul><li>Under Window | Preferences | Java | Build Path | Classpath Variables, create three new Classpath Variables called ANT_HOME, CATALINA_HOME, and HTTPUNIT_HOME. The values of these classpath variables should be the same as their corresponding environment variables.  </li><li>After you have done this, you should be able to import this project into your Eclipse workspace without error.  </li></ul></ol><h1>Invocation</h1><ol><li>Basic compilation </li></ol><p>To perform a basic compilation, invoke &quot;ant&quot;: </p><p>C:\photohunt&gt;ant </p><ol><li>Basic Web Deployment </li></ol><p>To deploy this web application, first invoke &quot;startup&quot; to bring up Tomcat.  </p><p>Once Tomcat is running, invoke &quot;ant -f tomcat.build.xml&quot;.  The results should look as follows: </p><p>C:\photohunt&gt;ant -f tomcat.build.xml </p><ol><li>The web interface </li></ol><p>The web interface is quite simple.  Go to <a href="http://localhost:8080/photohunt/" rel="nofollow">http://localhost:8080/photohunt/</a> to play around with it once you have successfully deployed the system.  </p><ol><li>Running JUnit Tests </li></ol><p>To run the JUnit tests over the system, invoke &#x27;ant -f junit.build.xml&#x27;. The results should look as follows: </p><p>C:\photohunt&gt;ant -f junit.build.xml </p><h1>Developer documentation</h1><p>This distribution includes Eclipse project definition files. In addition, it includes the following developer build files and targets. For the external tools (Checkstyle, PMD, FindBugs<a href="/p/photohunt/w/edit/FindBugs">?</a>, JUnit, SCLC), you must download them from their home pages, unzip them, and then set an environment variable (CHECKSTYLE_HOME, PMD_HOME, etc.) to point to this directory.  </p><ul><li>checkstyle.build.xml </li></ul><p>Requires: checkstyle 4.2 Runs Checkstyle on the system, using rules in lib/checkstyle/checkstyle.modules.xml Invocation: ant -f checkstyle.build.xml </p><ul><li>junit.build.xml </li></ul><p>Requires: JUnit 4.1 Runs JUnit on the system, using Test case code in src/<strong></strong>/Test<strong>.java. Invocation: ant -f junit.build.xml </strong></p><ul><li>javadoc.build.xml </li></ul><p>Runs JavaDoc<a href="/p/photohunt/w/edit/JavaDoc">?</a> on the system.  Invocation: ant -f javadoc.build.xml </p><ul><li>findbugs.build.xml </li></ul><p>Requires: FindBugs<a href="/p/photohunt/w/edit/FindBugs">?</a> 1.0.0 Runs FindBugs<a href="/p/photohunt/w/edit/FindBugs">?</a> on the system, using rules in lib/findbugs/findbugs.filter.xml Invocation: ant -f findbugs.build.xml </p><ul><li>pmd.build.xml </li></ul><p>Requires: PMD 3.7 Runs PMD on the system, using rules in lib/pmd/pmd.rulesets.xml Invocation: ant -f pmd.build.xml </p><ul><li>sclc.build.xml </li></ul><p>Requires: SCLC 2.4.525 Runs SCLC on the system. Invocation: ant -f sclc.build.xml </p><ul><li>dist.build.xml </li></ul><p>Creates a distribution zip file for this system. Invocation: ant -f dist.build.xml </p><h1>Contact information</h1><p>If you would like to know more about this software, or would like to be informed of future releases: </p><ul><li>Home page:  <a href="http://code.google.com/p/photohunt/" rel="nofollow">http://code.google.com/p/photohunt/</a> </li><li>Developer contact: Elayne Man (elaynem@hawaii.edu), George Lee (gelee@hawaii.edu) </li><li>Configuration management repository: <a href="http://photohunt.googlecode.com/svn/" rel="nofollow">http://photohunt.googlecode.com/svn/</a> </li><li>Developer and user mailing lists: <a href="http://groups.google.com/group/photohunt-discuss" rel="nofollow">http://groups.google.com/group/photohunt-discuss</a> </li></ul>

</body>
</html>
